﻿using System.Threading.Tasks;

namespace ElevatorDispatching
{
    /// <summary>
    /// 呼层呼梯信号处理器
    /// </summary>
    public interface ISignalHandler
    {
        /// <summary>
        /// 处理呼层呼梯信号
        /// </summary>
        /// <param name="signal">要处理的呼层呼梯信号</param>
        /// <returns>返回值指示该信号是否被处理</returns>
        bool HandleCallSignal(ICallSignal signal);

        /// <summary>
        /// 清除指定楼层指定方向上的呼梯信号
        /// </summary>
        /// <param name="floorId">楼层 Id</param>
        /// <param name="direction">呼梯信号的方向</param>
        void EraseCallCageSignals(int floorId, Direction direction);
    }
}
